<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>Obaju : e-commerce template</title>
    <meta name="description" content="">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="robots" content="all,follow">
    <!-- Bootstrap CSS-->
    <link rel="stylesheet" href="sourse/vendor/bootstrap/css/bootstrap.min.css">
    <!-- Font Awesome CSS-->
    <link rel="stylesheet" href="sourse/vendor/font-awesome/css/font-awesome.min.css">
    <!-- Google fonts - Roboto -->
    <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:100,300,400,700">
    <!-- owl carousel-->
    <link rel="stylesheet" href="sourse/vendor/owl.carousel/assets/owl.carousel.css">
    <link rel="stylesheet" href="sourse/vendor/owl.carousel/assets/owl.theme.default.css">
    <!-- theme stylesheet-->
    <link rel="stylesheet" href="sourse/css/style.default.css" id="theme-stylesheet">
    <!-- Custom stylesheet - for your changes-->
    <link rel="stylesheet" href="sourse/css/custom.css">
    <!-- Favicon-->
    <link rel="shortcut icon" href="favicon.png">
    <!-- Tweaks for older IEs--><!--[if lt IE 9]>
        <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
        <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]-->
  </head>
  <body>
    <div id="all">
      <div id="content">
        <div class="container">
          <div class="row">
            <div class="col-lg-3">
              <div class="card sidebar-menu">
                <div class="card-header">
                  <h3 class="h4 card-title">个人中心</h3>
                </div>
                <div class="card-body">
                  <ul class="nav nav-pills flex-column">
                    <a href="customer1" class="nav-link active"><i class="fa fa-list"></i> 我的订单</a>
                    <a href="customer2" class="nav-link"><i class="fa fa-list"></i> 我的地址</a>
                    <a href="customer3" class="nav-link"><i class="fa fa-user"></i>修改信息</a>
                    <a href="javascript:void(0)" onclick="window.parent.location.href = 'jump'" class="nav-link"><i class="fa fa-sign-out"></i>退出</a>
                  </ul>
                </div>
              </div>
              <!-- /.col-lg-3-->
              <!-- *** CUSTOMER MENU END ***-->
            </div>
            <div id="customer-orders" class="col-lg-9">
              <div class="box">
                <h1>我的订单</h1>
                <p class="lead">快看看你买了什么吧</p>
                <hr>
                <div class="table-responsive">
                  <table class="table table-hover">
                    <thead>
                      <tr>
                        <th>订单号</th>
                        <th>时间</th>
                        <th>总价</th>
                        <th>状态</th>
                        <th>行动</th>
                      </tr>
                    </thead>
                    <tbody>
                      <c:forEach items="${orders}" var="order">
                        <tr>
                          <th>${order.oid}</th>
                          <td>${order.ocreateDate}</td>
                          <td>￥${order.ocountPrice}</td>
                          <td><c:if test="${order.ostatus==0}">未支付</c:if><c:if test="${order.ostatus==1}">已支付</c:if>
                            <c:if test="${order.ostatus==2}">已发货</c:if><c:if test="${order.ostatus==3}">已签收</c:if>
                            <c:if test="${order.ostatus==4}">退货</c:if><c:if test="${order.ostatus==5}">已失效</c:if></td>
                          <td><a href="customer4?oid=${order.oid}" class="btn btn-primary btn-sm">详情</a></td>
                        </tr>
                      </c:forEach>
                    </tbody>
                  </table>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </div>
    <!-- JavaScript files-->
    <script src="sourse/vendor/jquery/jquery.min.js"></script>
    <script src="sourse/vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
    <script src="sourse/vendor/jquery.cookie/jquery.cookie.js"> </script>
    <script src="sourse/vendor/owl.carousel/owl.carousel.min.js"></script>
    <script src="sourse/vendor/owl.carousel2.thumbs/owl.carousel2.thumbs.js"></script>
    <script src="sourse/js/front.js"></script>
  </body>
</html>